<!DOCTYPE html>
<html>

<head>

<meta name="keywords" content="JavaScript, WebRTC" />
<meta name="description" content="WebRTC codelab" />
<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1">

<title>WebRTC codelab: step 2</title>

<style>
</style>

    <script src='js/lib/adapter.js'></script>

</head>

<body>

<video />

<script>

var constraints = {video: true};

function successCallback(stream) {
  window.stream = stream; // stream available to console
  var video = document.querySelector("video");
  video.src = window.URL.createObjectURL(stream);
  video.play();
}

function errorCallback(error){
  console.log("getUserMedia error: ", error);
}

getUserMedia(constraints, successCallback, errorCallback);
</script>

</body>

</html>
